#include "bsp_chipinfo.h"
#include "bsp_log.h"

chipinfo_t chipinfo;
union {
    uint32_t u32chipid;
    uint8_t u8chipid[4];
}chip_id;

void bsp_get_chipinfo(void)
{
    chipinfo.CHIPID = EFM_GetCID();
    EFM_GetUID(&chipinfo.uid);
    chip_id.u32chipid = chipinfo.CHIPID;
    LOG("chip info: %c%cSC,HC32F%x%x \r\n UID: 0x%x,0x%x,0x%x\r\n",chip_id.u8chipid[3],chip_id.u8chipid[2],chip_id.u8chipid[1],chip_id.u8chipid[0],chipinfo.uid.u32UniqueID0,chipinfo.uid.u32UniqueID1,chipinfo.uid.u32UniqueID2);    
}


